package com.mcxx.modules.base.service.write;

import com.mcxx.modules.base.dao.write.AreaMappingWriteDao;
import com.mcxx.modules.base.entity.AreaGroupEntity;
import com.mcxx.modules.base.entity.AreaMappingEntity;
import com.yinhai.ta404.core.service.BaseService;
import com.yinhai.ta404.core.transaction.annotation.TaTransactional;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
@TaTransactional
public class AreaMappingWriteService extends BaseService {
    @Autowired
    private AreaMappingWriteDao areaMappingWriteDao;


    public int updateInfoByFinanceId(AreaMappingEntity areaMappingEntity){
        return areaMappingWriteDao.updateInfoByFinanceId(areaMappingEntity);
    }

    public int insetAreaMappingList(List<AreaMappingEntity> allOrgAreaMappingList){
        return areaMappingWriteDao.insetAreaMappingList(allOrgAreaMappingList);
    }

    public int updateAreaMapping(AreaMappingEntity areaMappingEntity){
        return areaMappingWriteDao.updateAreaMapping(areaMappingEntity);
    }

    public int deleteAreaMappingById(String id){
        return areaMappingWriteDao.deleteAreaMappingById(id);
    }

    public int deleteAreaMappingByRescueCode(String rescueCode) {
        return areaMappingWriteDao.deleteAreaMappingByRescueCode(rescueCode);
    }


    public int insetAreaMapping(AreaMappingEntity areaMappingEntity){
        return areaMappingWriteDao.insetAreaMapping(areaMappingEntity);
    }
}
